#ifndef QUEUEMANAGER_H_INCLUDED
#define QUEUEMANAGER_H_INCLUDED
typedef struct ptrBlock{
	int name; //ID of child directory, file, block number
	int location; // location on hard disk of child
    int valid;  //If child is valid, open/close
}ptrBlock;

typedef struct file_control_block{
    int ID;    //ID of block, either directory id, file id, block number
    int frameType;    //1-dirhead, 2-filehead, 3-fileblock, 4-diviceheader,5-fs_header
    int parentPtr;    //pointer to parent location
    int badBlock;     //-1 if not bad, 0 if bad, >0 location of new block for this bad block
    int permission;   //0-new, 1-read, 2-read/write
    ptrBlock pointers[1024];   //list of children for block
	int ptrSize;      //size of pointers array, number of children for block
    int fileSystem;   //for file system header only, 0-not formatted, 1-formatted
    int mounted;      //for device header only, 0-not mounted, 1-mounted
	int data;         //random data for file blocks
	int nextIndex;    //pointer to next block in linked list
	int prevIndex;    //pointer to previoius block in lisked list
}file_control_block;
void Enqueue(int, int, int, int, int, ptrBlock*, int, int, int, int, int*, int*, int*, int*, file_control_block*);
file_control_block Dequeue(int*, int*, int*, int*, file_control_block*);
int Delete(int, int*, int*, int*, int*, file_control_block*);
void iniFree(int*, int*, int, file_control_block*);
void iniQueue(int*, int*, int*, int*, int*, file_control_block*, int, int);
#endif